﻿<%@ Page Title="" Language="C#" MasterPageFile="~/POS.master" AutoEventWireup="true" CodeFile="RoleManager.aspx.cs" Inherits="UserManagement_RoleManager" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="Server">
    <div>        
        <table style="width: 40%">
            <tr>
                <td class="text-right">Role Name:
                </td>
                <td style="width: 70%">
                    <input type="text" id="txtRoleName" />
                </td>
                <td>
                    <input type="button" value="Save" id="btnSaveRole" onclick="saveRole()" /></td>
            </tr>
        </table>
    </div>
    <div style="float: left; width: 48%;">

        <div class="divHeading">Roles </div>
        <table style="width: 50%" class="table-bordered">
            <thead>
                <tr>
                    <th>Role Name</th>
                </tr>
                
            </thead>
            <tbody id="tbodyRoles">
                <asp:Repeater ID="rptRoles" runat="server">
                    <ItemTemplate>
                        <tr class="pointer">
                            <td onclick="roleClick(this)">                               
                                <asp:Label ID="lblRoleName" runat="server" Text='<%# Bind("RoleName")%>'></asp:Label>                                                                
                                <input type="hidden" class="roleId" id="hdnRoleId" value='<%# Eval("RoleId")%>' />
                            </td>
                        </tr>
                    </ItemTemplate>
                </asp:Repeater>
            </tbody>
        </table>

    </div>

    <div style="float: left; width: 50%; padding-left: 2%;">
        <div class="divHeading">
            <span>Role Rights </span>
            <span><input type="button" id="btnSaveRoleRights" onclick="saveRoleRights()" /> </span>
        </div>
        <table class="table-bordered" style="width: 100%">
            <thead>
                <tr>
                    <th>Module</th>
                </tr>
            </thead>
            <tbody id="tbodyModuleRights">
            </tbody>
        </table>
    </div>
    <script src="RoleManager.js"></script>

</asp:Content>

